package com.example.kotlinview

 class Sample {
    val name by lazy {
        println("仅执行一次")
        "hello"
    }
    var age :Int?=null

    var age3:Int=0

    lateinit var name2:String
//    lateinit var age2:Int

    var name3:String="kotlin"
     get() {
         return field + " nb"
     }
     set(value) {
         field = "Cute " + value
     }
     val name4="final"
     get() {return field+"val只能调用get"}

}